	var xfid = null;
	// create the Data Store
	var proxy =  new Ext.data.HttpProxy({
            url: context + '/app/xflog.do?method=list'
        });
    var store = new Ext.data.JsonStore({
        root: 'list',
        totalProperty: 'totalSize',
        idProperty: 'LOGID',
        remoteSort: true,

        fields: [
            'L_DATE', 'L_GROUPNAME', 'L_MEMO', 'L_USERNAME',
            'L_TYPE','L_GROUPNAME'
        ],

        // load using script tags for cross domain, if the data in on the same domain as
        // this page, an HttpProxy would be better
        proxy:proxy
    });
    store.setDefaultSort('L_DATE', 'desc');
	proxy.on('beforeload', function(proxy, params) {
				params.id = xfid;
			}, this);
    var grid = new Ext.grid.GridPanel({
        layout:'fit',
        frame : false,
        border : false,
        store: store,
        trackMouseOver:false,
        disableSelection:true,
        loadMask: true,
        autoExpandColumn: 'L_MEMO',

        // grid columns
        columns:[
        new Ext.grid.RowNumberer({width: 30}),
        {
            id: 'L_DATE', // id assigned so we can apply custom css (e.g. .x-grid-col-topic b { color:#333 })
            header: "操作时间",
            dataIndex: 'L_DATE',
            width: 100,
            sortable: true
        },{
            header: "操作人",
            dataIndex: 'L_USERNAME',
            width: 80,
            sortable: true
        },{
            header: "所在部门",
            dataIndex: 'L_GROUPNAME',
            width: 80,
            sortable: true
        },{
            header: "操作类型",
            dataIndex: 'L_TYPE',
            width: 70,
            sortable: true
        },{ id : "L_MEMO",
            header: "操作内容",
            dataIndex: 'L_MEMO',
            sortable: true
        }],


        // paging bar on the bottom
        bbar: new Ext.PagingToolbar({
            pageSize: 10,
            store: store,
            displayInfo: true,
            displayMsg: '显示记录 {0} - {1} of {2}',
            emptyMsg: "没有记录"
        })
    });
    
    var win;
    
    
    if(typeof(win)=='undefined'||win == null){
    	win = new Ext.Window({
                layout:'fit',
                title:'事件列表',
                width:700,
                height:310,
                modal : true,
                id : 'xfLogWindow',
                closeAction:'hide',
                items: grid
            });
    }
    
            
/**
 * 显示操作日志窗口
 * @param {} id
 */   
function showLogWin(id){
	xfid = id;
    store.load({params:{start:0, limit:10,id:id}});
    win.show();
}